const mongoose = require('mongoose');
var mongoosePaginate = require('mongoose-paginate');

var schema = new mongoose.Schema({
  title: String,//标题
  subtitle: String,//副标题
  content: String,//内容
  parentcate:String,//父级分类名称
  nowcate:String,//当前分类名称
  pushtime:Date,//上传时间
  author:String,//作者
  keyword:String,//关键字
  source:String,//来源
  reporter:String,//记者
  commentnum:Number,
  belong:String//父级ID
});
schema.plugin(mongoosePaginate);

module.exports = mongoose.model('News', schema);


